Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> logowanie po raz nty, warning: headers blabla bla
fiszol
post
Post #1





Grupa: Zarejestrowani
Postów: 453
Pomógł: 16
Dołączył: 25.05.2004
Skąd: Gorzów Wlkp.

Ostrzeżenie: (0%)
-----


A więc tak, skrypt jako taka działa, jednak zawsze widnijeje u góry treść erroru:

Cytat
Warning: session_start(): Cannot send session cookie - headers already sent by (output started at c:\usr\krasnal\www\ffs\admin\index.php:6) in c:\usr\krasnal\www\ffs\admin\index.php on line 8

Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at c:\usr\krasnal\www\ffs\admin\index.php:6) in c:\usr\krasnal\www\ffs\admin\index.php on line 8


A skrypt wygląda tak:

  1. <?
  2. require '../conf.php' ;
  3. $real_user=&#092;"fiszol\";
  4. $real_pass=&#092;"pass\";
  5.  
  6. echo &#092;"<font color=330000>\" ;
  7. if ($admin==&#092;"zaloguj\") {
  8.  
  9. if ($zUser==$real_user and $zPass==$real_pass) {
  10. $usr=$zUser;
  11. $pass=$zPass;
  12.  
  13.  session_register('usr');
  14.  session_register('pass');
  15.  
  16.  
  17. }
  18. }
  19.  
  20.  
  21. if (($usr==$real_user) && ($pass==$real_pass))
  22. { /* tresć dostępna po zalogowaniu*/ }
  23.  
  24. else {
  25. echo&#092;"<font face=arial size=3 color=FF0000><div align=center><b>Nie masz uprawnień!<br><br>\" ;
  26. echo &#092;"<table align=center width=40% border=0 cellspacing=0>\";
  27. echo &#092;"<tr><td colspan=2><br><div align=center><font color=green face=arial size=4><b>Mu-bySiteAdmin</font></div><br>\";
  28. echo &#092;"<form method=post action=index.php?admin=zaloguj>\";
  29. echo &#092;"<tr><td width=40%><div align=center><font class=tresc> login: </td><td align=center><input type=text name=zUser size=10 width=20></td></tr>\";
  30. echo &#092;"<tr><td width=40%><div align=center><font class=tresc> passw: </td><td align=center><input type=password name=zPass size=10 width=20></td></tr>\";
  31. echo &#092;"<td align=center colspan=2><input type=submit name=submit value=zaloguj></td></tr>\";
  32. echo &#092;"</form></table>\";
  33.  
  34.  }
  35. ?>


Co zrobić aby zlikwidować ten błąd?

przetrzepałem już istniejące tematy jednak rozwiązanie nie znalzłem, tzn są inne skrypty z już omówioną problematyką jednak jak na mnie zbyt skomplikowane

pozdrawiam,
fiszol
Go to the top of the page
+Quote Post

Posty w temacie


Closed TopicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 10.10.2025 - 07:52